import Vue from "vue";
import Vuex from "vuex";
import home from './mutations/home'

Vue.use(Vuex);

export default new Vuex.Store({
  state: {
    tabIndex: 0,
    favorCount: 9918
  },
  mutations: {
    SET_TAB_INDEX(state, val) {
      state.tabIndex = val
    }
  },
  actions: {
    setTabIndex({commit}, val) {
      commit('SET_TAB_INDEX', val)
    }
  },
  modules: {
    home
  }
});
